#ifndef QS_H100AP_PY32F002B_HAL_H_
#define QS_H100AP_PY32F002B_HAL_H_

#define QS_USING_KEY
//#define QS_USING_LED


//#ifdef QS_USING_LED
//#define QS_LED1_PORT              GPIOB
//#define QS_LED1_PIN              GPIO_PIN_2
//#define QS_LED2_PORT              GPIOA
//#define QS_LED2_PIN              GPIO_PIN_6
//#define QS_LED3_PORT              GPIOA
//#define QS_LED3_PIN              GPIO_PIN_5
//#endif

#define QS_PWR_CTRL_PORT        GPIOB
#define QS_PWR_CTRL_PIN         GPIO_PIN_7

#ifdef QS_USING_KEY
#define QS_KEY1_PORT              GPIOB
#define QS_KEY1_PIN              GPIO_PIN_4         //Timer k1
#define QS_KEY2_PORT              GPIOB
#define QS_KEY2_PIN              GPIO_PIN_3         //Heat_UP k2
#define QS_KEY3_PORT              GPIOB
#define QS_KEY3_PIN              GPIO_PIN_2         //Heat_Down k3
#define QS_KEY4_PORT              GPIOB
#define QS_KEY4_PIN              GPIO_PIN_1         //Auto k4
#define QS_KEY5_PORT              GPIOB
#define QS_KEY5_PIN              GPIO_PIN_0         //?
#define QS_KEY6_PORT              GPIOA
#define QS_KEY6_PIN              GPIO_PIN_1          //Fan_Down k5
#define QS_KEY7_PORT              GPIOA
#define QS_KEY7_PIN              GPIO_PIN_3          //Fan_up k6
#define QS_KEY8_PORT              GPIOA
#define QS_KEY8_PIN              GPIO_PIN_4          //Power k7
#endif 


#define QS_UART_TX_PORT         GPIOA
#define QS_UART_TX_PIN         GPIO_PIN_6
#define QS_UART_TX_AF         GPIO_AF1_USART1

#define QS_UART_RX_PORT         GPIOA
#define QS_UART_RX_PIN         GPIO_PIN_7
#define QS_UART_RX_AF         GPIO_AF1_USART1
#endif